package com.ymk.service.impl;

import com.ymk.base.mybatis.DaoRouter;
import com.ymk.base.mybatis.Pagination;
import com.ymk.bo.user.SopUserBO;
import com.ymk.service.ISopUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;
/**
 * <p>
 * 平台用户表 服务实现类
 * </p>
 *
 * @author 莫参商
 * @since 2023-05-05
 */
@Service
public class SopUserService implements ISopUserService {

    @Override
    public SopUserBO get(Map param) {
    return this.daoRouter.queryForObject("SopUser.loadSopUser",param);
    }

    @Override
    public List<SopUserBO> list(Map param) {
        return this.daoRouter.query("SopUser.loadSopUser",param);
    }

    @Override
    public List<SopUserBO> listForPage(Pagination pagination) {
        return this.daoRouter.query("SopUser.loadSopUserForPage",pagination);
    }

    @Override
    public void post(SopUserBO param) {
        this.daoRouter.insert("ASopUser.insertSopUser",param);
    }

    @Override
    public void update(SopUserBO param) {
        this.daoRouter.update("ASopUser.updateSopUser",param);
    }

    @Override
    public void del(SopUserBO param) {
        this.daoRouter.update("ASopUser.delSopUser",param);
    }

    @Autowired
    private DaoRouter daoRouter;

}
